//
//  ViewController.m
//  yiyiiyiyiyiyiy
//
//  Created by lanouhn on 16/7/18.
//  Copyright © 2016年 喜羊羊. All rights reserved.
//

#import "ViewController.h"

@interface ViewController ()

@end

@implementation ViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    NSLog(@"nnnnnnn");
    NSLog(@"宝勋啊!");
    NSLog(@"你虚了");
    NSLog(@"嘎嘎嘎嘎嘎");
    UITextField *tf=[[UITextField alloc]initWithFrame:CGRectMake(100, 100, 200, 50)];
    tf.tag=500;
    tf.placeholder=@"请输入内容";
    tf.borderStyle=UITextBorderStyleBezel;
    [self.view addSubview:tf];
    
    UIButton *bu = [UIButton buttonWithType:UIButtonTypeCustom];
    bu.frame = CGRectMake(100, 250, 150, 50);
    
    [bu setTitle:@"返回上一界面" forState:UIControlStateNormal];
    [bu setTitleColor:[UIColor blueColor] forState:UIControlStateNormal];
    
    [bu addTarget:self action:@selector(handleBu:) forControlEvents:UIControlEventTouchUpInside];
    [self.view addSubview:bu];



    NSLog(@"nnnnnnn");
    NSLog(@"宝勋啊!");
    NSLog(@"你虚了");
    NSLog(@"嘎嘎嘎嘎嘎");

    NSLog(@"nnnnnnn");
    NSLog(@"宝勋啊!");
    NSLog(@"你虚了");
    NSLog(@"嘎嘎嘎嘎嘎");

    NSLog(@"nnnnnnn");
    NSLog(@"宝勋啊!");
    NSLog(@"你虚了");
    NSLog(@"嘎嘎嘎嘎嘎");



    NSLog(@"1231231321321231321321231231231231");

    

    
    
    dispatch_async(dispatch_get_global_queue(DISPATCH_QUEUE_PRIORITY_DEFAULT, 0), ^{
        //代码子线程中执行
        
        
        //串行队列
        dispatch_async(dispatch_get_main_queue(), ^{
            //代码主线程中执行
            
            
        });
        
    });
    NSLog(@"nnnnnnn");
    NSLog(@"宝勋啊!");
    NSLog(@"你虚了");
    NSLog(@"嘎嘎嘎嘎嘎");


}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

@end
